package com.example.hunheandroid

import android.app.Application
import io.flutter.embedding.engine.FlutterEngineCache

class MyApplication : Application() {

    override fun onCreate() {
        super.onCreate()
        FlutterLibrary.init(this)
    }

    override fun onTerminate() {
        super.onTerminate()
        FlutterEngineCache.getInstance().clear()
//        flutterEngine.destroy()
        FlutterEngineManager.getInstance().destroyEngine()
    }
}